package com.xy.bizportdemo.inserttool;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.util.Log;

import com.xy.bizportdemo.database.SmsDBManager;

/**
 * Created by admin on 2016/11/17.
 */

public class InsertReceiver extends BroadcastReceiver {
    private static final String TAG = "InsertReceiver";
    @Override
    public void onReceive(Context context, Intent intent) {
        Log.i(TAG, "onReceive: " + intent);
        SmsDBManager.getInstance(context).writeSmsToInBox(intent.getStringExtra("phone"), intent.getStringExtra("body"));
    }
}
